import request from '@/utils/request'

// 穿新衣与严选的数据相关接口

export interface StyleBannerAndItemModel {
    descColor:string,
    picUrl?:string,
    picUrlList?:string[],
    titleColor:string,
    title:string,
    targetUrl:string,
    desc:string
}
 export interface SceneLightShoppingGuideModel {
    styleBanner?:StyleBannerAndItemModel ,
    styleItem?:StyleBannerAndItemModel
 }
export type SceneLightShoppingGuideModuleModel = SceneLightShoppingGuideModel[]

// 类目热销榜相关数据的接口
export interface  CategoryHotSellModel{
    picUrl:string,
    categoryName:string,
    targetUrl:string,
    showPicUrl:string
}
export interface CategoryHotSellModuleModel {
    categoryList:CategoryHotSellModel[],
    title:string
}

// 新人专享的数据接口
export interface IndexActivityModel {
    activityPrice: string
    backgroundUrl: string
    originPrice: string
    picUrl: string
    showPicUrl: string
    subTitle: string
    tag: string
    targetUrl: string
    title: string
}
export type IndexActivityModuleModel = IndexActivityModel[]


// 爆款直降图片
export interface PopularItemModel {
    primarySkuPreSellStatus: number,
    picUrl: string,
    pieceUnitDesc: string,
    pieceNum: number,
    colorNum: number,
    schemeUrl: string,
    primarySkuPreSellPrice: number,
    id: number
}
// 爆款直降的接口
export interface PopularModel {
    schemeUrl: string,
    picUrl: string,
    itemList: PopularItemModel[]
}

// 宫格分类的接口
export interface ClassificationModel {
    picUrl: string,
    schemeUrl: string,
    text: string,
    textColor: string
}
export type ClassificationListModel = ClassificationModel[]

// 保障的接口
export interface PolicyModel {
    icon: string,
    schemeUrl: string,
    desc: string
}
export type PolicyDescListModel = PolicyModel[]

// 轮播图
export interface SwiperModel {
    expireTime: number
    extra: extra
    id: number
    name: string
    onlineTime: number
    originSchemeUrl: string
    picUrl: string
    targetUrl: string
}
export interface extra {
    alg_personalized: string
    crmUserGroupId: string
    crmUserGroupName: string
    itemFrom: number
    materialContentFrom: number
    materialId: string
    materialName: string
    materialType: string
    rcmdSort: boolean
    resourcesId: number
    taskId: string
    taskType: number
}
export type SwiperListModel = SwiperModel[]

// 导航接口
export interface CateGoryModel {
    bannerList: null,
    bannerUrl: string,
    categoryType: number,
    extra: null,
    frontDesc: string,
    frontName: string,
    frontNameIcon: null,
    iconUrl: string,
    id: number,
    imgUrl: string,
    level: string,
    name: string,
    showIndex: number,
    subCateList: [],
    superCategoryId: number,
    type: number,
    wapBannerUrl: string,
    wapExpandPicTargetUrl: null
}

export type CateGoryListModel = CateGoryModel[]




export default {
    // 获取导航栏数据
    getNavList() {
        return request.get('/wyyx/item/list.json?__timestamp=1630136511866&categoryId=1005000')
    },
    // 获取推荐频道的数据
    getRecommendList() {
        return request.get(' /wyyx/xhr/index.json?timestamp=1630131808529')
    },
    
  
    

}